/*
 * Copyright @ 2024 weili23
 * com.sky.mapper 11:13
 * All right reserved.
 */

package com.sky.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.sky.dto.GoodsSalesDTO;
import com.sky.entity.Orders;
import org.apache.ibatis.annotations.Mapper;

import java.time.LocalDateTime;
import java.util.List;

/**
 * @desc:
 * @author: weili23
 * @createTime: 2024/11/11 11:13
 * @version: v1.0
 */
@Mapper
public interface OrderMapper extends BaseMapper<Orders> {

    /**
     * @desc: 查询统计额
     * @author: weili23
     * @Date: 2024/11/14 11:33
     * @version: 1.0
     */
    Double getTurnOverStatistics(LocalDateTime startTime, LocalDateTime endTime, Integer completed);

    /**
     * @desc: 统计订单信息
     * @author: weili23
     * @Date: 2024/11/21 15:07
     * @version: 1.0
     */
    Integer getOrdersStatistics(LocalDateTime startTime, LocalDateTime endTime, Integer completed);

    /**
     * @desc: 获取top10订单
     * @author: weili23
     * @Date: 2024/11/21 16:22
     * @version: 1.0
     */
    List<GoodsSalesDTO> getTop10(LocalDateTime startTime, LocalDateTime endTime);
}
